<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>

<%@include file="../../WEB-INF/jspf/admin.jspf" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
        <link href="../../jq/redmond/jquery-ui-1.10.3.custom.min.css" type="text/css" rel="stylesheet"/>
        <link href="../../css/main.css" type="text/css" rel="stylesheet"/>
        <link href="../../jq/menu/menu.css" type="text/css" rel="stylesheet"/>
        <link href="../../jq/menu/submenu.css" type="text/css" rel="stylesheet"/>

        <link href="../../parainfo/table/table.css" type="text/css" rel="stylesheet"/>

        <script src="../../jq/jquery-1.10.2.min.js" type="text/javascript"></script>
        <script src="../../jq/jquery-ui-1.10.3.custom.min.js" type="text/javascript"></script>
        <script src="../../jq/i18n/jquery.ui.datepicker-es.min.js" type="text/javascript"></script>
        <script src="../../jq/menu/menu.js" type="text/javascript"></script>
        <script src="../../jq/menu/submenu.js" type="text/javascript"></script>

        <script src="../../parainfo/table/table.js" type="text/javascript"></script>
        <script src="js/terminales.js" type="text/javascript"></script>
    </head>
    <body>
        <div id="ctop">
            <%@include file="../../WEB-INF/jspf/top.jspf" %>
        </div>

        <div id="m_menu">
            <%@include file="../../WEB-INF/jspf/menu.jspf" %>
        </div>

        <div id="cmenu2">
            <%@include file="../../WEB-INF/jspf/submenu.jspf" %>
        </div>

        <div id="cdata">
            <table style="margin: auto">
                <th><h1>Mantenimiento de Terminales</h1></th>
                <th>&nbsp;</th>
                <tr>
                    <td style="vertical-align: top">

                        <table class="parainfo" style="width: 700px">
                            <thead>
                                <tr>
                                    <td>&nbsp;</td>
                                    <td>Descripción</td>
                                    <td>Tipo</td>
                                    <td>IP</td>
                                    <td>MAC</td>
                                    <td>Marca</td>
                                    <td>Modelo</td>
                                    <td>Estado</td>
                                </tr>
                            </thead>

                            <tbody id="qbody">
                                <tr>
                                    <th><input type="radio"/></th>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                </tr>
                                <tr>
                                    <th><input type="radio"/></th>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                </tr>
                            </tbody>
                        </table>
                    </td>

                    <td style="vertical-align: top">
                        <table class="crud">
                            <tr>
                                <td>
                                    <a href="#" onclick="jsBus();" title="Buscar">
                                        <img src="../../images/find.png"/></a>
                                </td>
                                <td>
                                    <a href="#" onclick="jsIns();" title="Nuevo">
                                        <img src="../../images/ins.png"/></a>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    <a href="#" onclick="jsCon();" title="Consultar">
                                        <img src="../../images/find2.png"/></a>
                                </td>
                                <td>
                                    <a href="#" onclick="jsUpd();" title="Modificar">
                                        <img src="../../images/upd.png"/></a>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    <a href="#" onclick="jsEst();" title="Cambiar Estado">
                                        <img src="../../images/upd_est.png"/></a>
                                </td>
                                <td>
                                    <a href="#" onclick="jsExcel();" title="Exportar a Excel">
                                        <img src="../../images/excel.png"/></a>
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
            </table>

            <%-- para busquedas  --%>
            <div style="display: none">
                <div id="dbus" title="B&uacute;squeda de Terminal">
                    <table>
                        <tr>
                            <td>Estado</td>
                            <td>
                                <input type="radio" name = "id_est" id = "estado" value = "R" checked /> Registrado
                                <input type="radio" name = "id_est" id = "estado" value = "A"/> Asignado
                                <input type="radio" name = "id_est" id = "estado" value = "B"/> Baja
                            </td>
                        </tr>

                        <tr>
                            <td>IP</td>
                            <td><input type="text" id="ip_bus" maxlength="25" style="width: 200px"/></td>
                        </tr>

                        <tr>
                            <td>Marca</td>
                            <td><input type="text" id="marca_bus" maxlength="50" style="width: 400px"/></td>
                        </tr>

                    </table>

                    <p id="error_bus" style="color: red"></p>
                </div>
            </div>

            <%-- para INS  --%>
            <div style="display: none">
                <div id="dins" title="Nuevo registro">
                    <table>
                        <tr>
                            <td>ID&nbsp;Terminal</td>
                            <td colspan="2">
                                <input type="text" id="idterminal_ins" 
                                       maxlength="15" style="width: 100px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>Descripción</td>
                            <td colspan="2">
                                <input type="text" id="descripcion_ins" 
                                       maxlength="200" style="width: 370px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>ID&nbsp;Tipo</td>
                            <td colspan="2">
                                <input type="text" id="idtipo_ins" 
                                       maxlength="15" style="width: 100px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>IP&nbsp;Terminal</td>
                            <td colspan="2">
                                <input type="text" id="ip_ins" 
                                       maxlength="25" style="width: 150px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>MAC&nbsp;Terminal</td>
                            <td colspan="2">
                                <input type="text" id="mac_ins" 
                                       maxlength="25" style="width: 150px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>Marca</td>
                            <td colspan="2">
                                <input type="text" id="marca_ins" 
                                       maxlength="50" style="width: 300px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>Modelo</td>
                            <td colspan="2">
                                <input type="text" id="modelo_ins" 
                                       maxlength="50" style="width: 300px"/>
                            </td>
                        </tr>
                    </table>

                    <p id="error_ins" style="color: red"></p>
                </div>
            </div>

            <%-- para consulta  --%>
            <div style="display: none">
                <div id="dcon" title="Consulta de Trabajador">


                    <p id="error_con" style="color: red"></p>
                </div>
            </div>

            <%-- para UPD  --%>
            <div style="display: none">
                <div id="dupd" title="Actualizar registro">
                    <input type="hidden" id="idterminal"/>
                    <input type="hidden" id="idestado"/>
                    <table>
                        <tr>
                            <td>ID&nbsp;Terminal</td>
                            <td colspan="2">
                                <input type="text" id="idterminal_upd" 
                                       maxlength="15" style="width: 100px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>Descripción</td>
                            <td colspan="2">
                                <input type="text" id="descripcion_upd" 
                                       maxlength="200" style="width: 370px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>ID&nbsp;Tipo</td>
                            <td colspan="2">
                                <input type="text" id="idtipo_upd" 
                                       maxlength="15" style="width: 100px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>IP&nbsp;Terminal</td>
                            <td colspan="2">
                                <input type="text" id="ip_upd" 
                                       maxlength="25" style="width: 150px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>MAC&nbsp;Terminal</td>
                            <td colspan="2">
                                <input type="text" id="mac_upd" 
                                       maxlength="25" style="width: 150px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>Marca</td>
                            <td colspan="2">
                                <input type="text" id="marca_upd" 
                                       maxlength="50" style="width: 300px"/>
                            </td>
                        </tr>
                        <tr>
                            <td>Modelo</td>
                            <td colspan="2">
                                <input type="text" id="modelo_upd" 
                                       maxlength="50" style="width: 300px"/>
                            </td>
                        </tr>
                    </table>

                    <p id="error_upd" style="color: red"></p>
                </div>
            </div>

            <%-- para estado  --%>
            <div style="display: none">
                <div id="dest" title="Actualizar registro">


                    <p id="error_est" style="color: red"></p>
                </div>
            </div>

            <%-- para mensajes  --%>
            <div style="display: none">
                <div id="dmsg" title="Mensaje">
                    <p id="msg" style="text-align: center;color: #800;margin: 20px"></p>
                </div>
            </div>
        </div>

        <%-- para excel  --%>
        <form id="to_excel" action="TrabajadoresExc" target="_parent" method="post">
            <input type="hidden" id="data_excel" name="data_excel"/>
        </form>
    </body>
</html>

